package org.etlt.expression.function;

import org.etlt.expression.VariableContext;

import java.lang.reflect.InvocationTargetException;
import java.util.List;

public interface FunctionExecutor {
	Object invokeFunction(VariableContext context, String functionName, Object[] parameters)
			throws NoSuchMethodException, IllegalAccessException, InvocationTargetException;

	FunctionInvoker getFunction(String functionName);

	default List<FunctionInvoker> getAllFunctions(){
		throw new UnsupportedOperationException();
	}

	default void registerFunctions(String type){};
}
